{{ template "header_start" .}}
{{ template "firmware" .}}
{{ template "global" .}}
{{ template "bootstrap" .}}
{{ template "datetimepicker" .}}
{{ template "header_end" .}}
{{ template "nav" .}}

<section class="option ul-horizontal">
<ul>
<li><h3 class="jk-text-info">项目规划<a href="#" data-toggle="modal" data-target="#js-additem" class="btn btn-info">添加</a></h3></li>
<li>
<div class="col-xs-4">
<input type="text" class="form-control"  placeholder="写个名字，我去找找看" />
</div>
<span type="search" class="btn btn-info" id="search">搜索</span>
</li>
</ul>
<div class="search-result ul-horizontal no-display">
<table class="table">
<thead>
	<tr><td>任务</td><td>详述</td><td>平台</td><td>开始时间</td><td>结束时间</td><td>完成情况</td></tr>
</thead>
<tbody>
</tbody>
</table>
<hr class="red-line" />
</div>
</section>
<hr/>

<div class="modal fade" id="js-additem" role="dialog" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<header class="modal-header">
	<button type="button" class="close jk-close" data-dismiss="modal" aria-hidden="true">×</button>
	<h3 class="modal-title title jk-text-danger">添加条目</h3>
</header>
<section class="modal-body">
<dl class="">
    <dt>名称</dt>
    <dd><input class="jk-input-text jk-input-large" type="text" name="name" placeholder="任务名称" required/></dd>
    <dt>平台</dt>
    <dd><input class="jk-input-text jk-input-large" type="text" name="classify" placeholder="任务类型" required/></dd>
    <dt>描述</dt>
    <dd><div class="jk-input-text" name="content"><span class="tips">What you want to record ...</span></div></dd>
    <dt>开始时间：</dt>
    <dd><input class="input-text input-middle jk-datetimepicker " name="starttime" placeholder="开始时间" required/></dd>
    <dt>结束时间：</dt>
    <dd><input class="input-text input-middle jk-datetimepicker" name="stoptime" placeholder="结束时间" required/></dd>
    <dt>负责人：</dt>
    <dd><input class="input-text input-middle" name="operate" placeholder="负责人" required/></dd>
</dl>
</section>
<footer class="modal-footer">
	<button class="btn btn-info ownsure">确定</button>
	<br class="clear" />
</footer>
</div>
</div>
</div>

<div class="ul-horizontal ownbug">
<table class="table table-hover">
<thead>
	<tr><td>任务</td><td>详述</td><td>平台</td><td>开始时间</td><td>结束时间</td><td>完成情况</td><td>负责人</td></tr>
</thead>
<tbody>
{{ range $ownbug := .D.Body.firmware }}
<tr>
	<td class="col-xs-5"><input class="form-control" type="text" name="name" value="{{ $ownbug.Name }}" disabled/></td>
	<td><div class="jk-input-text-none" name="content">{{$ownbug.Content}}</div></td>
	<td class="col-xs-3"><input class="form-control" type="text" name="classify" value="{{ $ownbug.Classify }}" disabled/></td>
	<td><div name='createtime' class="time">{{ UnixToStr $ownbug.StartTime}}</div></td>
	<td><div name='downtime' class="time">{{ UnixToStr $ownbug.StopTime}}</div></td>
	<td>{{ if $ownbug.Fixed }} <div name='upgradetime' class="time">{{ UnixToStr $ownbug.UpdateTime}}</div> {{ else }}
		<input type='checkbox' name="fixed" value="fixed" />完成{{end}}</td>
	<td class="col-xs-3"><input name='operate' class="form-control" value="{{$ownbug.Operate}}" disabled></input></td>
	<td><button class='mod btn btn-warn'>修改</button><button class='del btn btn-danger'>删除</button></td>
</tr>
{{ end }}
</tbody>
</table>
<input type="hidden" name="mode" value="ownbug">
</div>


{{ template "footer" . }}